package com.liner.homework.third;

public class StringBuilderDemo {
    public static void main(String[] args) {
        //append()追加、replace()替换、delete()删除、insert()插入
        StringBuilder sb = new StringBuilder("123");
        sb.append("444");
        System.out.println("append:" + sb);

        sb.replace(1,4,"555");
        System.out.println("replace:" + sb);

        sb.delete(3,4);
        System.out.println("delete:" + sb);

        sb.insert(1,"666");
        System.out.println("insert:" + sb);

    }
}
